package onlinecalsys.server.controller;

import java.rmi.Remote;
import java.rmi.RemoteException;
import java.util.ArrayList;

import onlinecalsys.client.controller.ClientController;
import onlinecalsys.client.view.ObserverCommon.Observer;
import onlinecalsys.server.objects.Appointment;

public interface ServerController extends Remote {
	
	void attach(Observer client) throws RemoteException;
	void notifyObservers(String username) throws RemoteException;;
	void dettach(String username) throws RemoteException;
	
	boolean addApointment(Appointment app) throws RemoteException;

	ArrayList<ArrayList<String>> getAppointments(String date, String username) throws RemoteException;

	boolean deleteAppointment(int appointmentId, String username) throws RemoteException;

	boolean usernameChecking(String username, String password) throws RemoteException;

	boolean saveNote(String note,String username)throws RemoteException;
	String getNote(String username)throws RemoteException;

	boolean shareAppointment(String username, int id, String shareWithUser) throws RemoteException;
	
	ArrayList<ArrayList<String>> getSharedAppointments(String username)throws RemoteException;
	
	boolean createNewUser(String username, String password) throws RemoteException;


}
